const state = {
  showMathEditor: false,
  mathType: 'inline',
  mathContent: ''
  // 删除 keyboardVisible
}

const mutations = {
  SET_MATH_EDITOR_STATE(state, { show, type, content = '' }) {
    state.showMathEditor = show
    state.mathType = type
    state.mathContent = content
  }
  // 删除 TOGGLE_KEYBOARD mutation
}

const actions = {
  TOGGLE_MATH_EDITOR({ commit }, { show, type, cursor, content = '' }) {
    commit('SET_MATH_EDITOR_STATE', {
      show,
      type,
      content
    })
  }
}

export default { state, mutations, actions }
